home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 138
/
Volume 138 Aug 19 2011 - Damaged.iso
/
Games
/
shadez.swf
/
scripts
/
Local
/
Audio
/
CSample.as
< prev
next >
Wrap
Text File
|
2011-08-19
|
1KB
|
51 lines
package Local.Audio
{
import flash.media.Sound;
import flash.media.SoundChannel;
import flash.media.SoundTransform;
public class CSample
{
private var mSoundObject:Sound;
private var mStartTime:int;
public var mID:String;
private var mLoop:int;
public var mChannels:int;
public function CSample(param1:String, param2:Class, param3:int = 0, param4:int = 0, param5:int = 1)
{
super();
mID = param1;
mSoundObject = new param2();
mChannels = param5;
mStartTime = param3;
mLoop = param4;
}
public function Start(param1:SoundTransform, param2:uint = 0) : SoundChannel
{
return mSoundObject.play(param2 && !mLooping ? Number(param2) : Number(mStartTime),mLoop,param1);
}
public function get mLength() : uint
{
return mSoundObject.length;
}
public function get mLooping() : Boolean
{
return mLoop > 0;
}
public function Dispose() : void
{
}
}
}